<link rel="stylesheet" href="/assets/home/css/coupon_info.css" />

<body>
    <div class="coupon_cover">
        <img src="{$coupon.thumb_text}" style="max-width: none; width: 100%;">
    </div>

    <header class="mui-bar mui-bar-nav mui-bar-nav-bg">
        <a id="icon-menu" class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
        <h1 class="mui-title">优惠券</h1>
    </header>

    <div class="coupon_detail">
        <div class="coupon_info">
            <div class="left">
                <div class="left_top">
                    <div>
                        <span>{$coupon.rate * 100}</span>折
                    </div>
                    <div class="top_info">
                        <div>优惠券</div>
                        <div>COUPON</div>
                    </div>
                </div>
            </div>
            <div class="receive">
                {if condition="$coupon.receive_text"}
                    <button class="mui-btn mui-btn-primary" disabled>已领取</button>
                {else /}
                    <a href="{:url('home/coupon/receive', ['cid' => $coupon.id])}" class="mui-btn mui-btn-warning">立即领取</a>
                {/if}
            </div>
        </div>
        <div class="coupon_prompt">
            <div class="prompt_title">温馨提示：</div>
            <div><span>•</span>活动开始时间: {$coupon.createtime_text}</div>
            <div><span>•</span>活动结束时间: {$coupon.endtime_text}</div>
            <div><span>•</span>领取数量: {$coupon.total}张 每人限领1张</div>
        </div>
    </div>
</body>